import Vue from "vue";
import Router from "vue-router";
import index from "@/components/index";
import TopSubfield from "@/components/top/TopSubfield";
import centerTop from "@/components/center/centerNavigation/centerTop";
import Login from "@/components/top/login";
import bottomSynopsis from "@/components/bottom/bottomSynopsis";
import msgrelease from "@/components/center/centerNavigation/msgrelease/msgrelease";
import msgreleasestep2 from "@/components/center/centerNavigation/msgrelease/msgreleasestep2";
import releaseSuccess from "@/components/center/centerNavigation/msgrelease/releaseSuccess";
import broadsideNgn from "@/components/bottom/broadsideNgn";
import centerSearch from "@/components/top/centerSearch";
import detailsContent from "@/components/CommonComponents/shopdetails/detailsContent";
import storeinformation from "@/components/CommonComponents/shopdetails/storeinformation";
import feedback from "@/components/CommonComponents/otherpage/feedback";
import Hlpcenter from "@/components/CommonComponents/otherpage/hlpcenter";
import campus from "@/components/CommonComponents/otherpage/report";
import report from "@/components/CommonComponents/otherpage/report";
import protection from "@/components/CommonComponents/otherpage/protection";
import submitOrder from "@/components/CommonComponents/shopdetails/submitOrder";
import confirmPayment from "@/components/CommonComponents/shopdetails/confirmPayment";
import orderFulfillment from "@/components/CommonComponents/otherpage/orderFulfillment";
import articleDetails from "@/components/top/articleDetails";
import aboutUs from "@/components/CommonComponents/otherpage/aboutUs";
import appdownload from "@/components/CommonComponents/otherpage/appdownload";
import application from "@/components/CommonComponents/agent/application";
import directions from "@/components/CommonComponents/agent/directions";
import detailsTop from "@/components/top/detailsTop";
import entering from "@/components/CommonComponents/entering/entering";
import Settled from "@/components/CommonComponents/entering/settled";
import shopmenu from "@/components/CommonComponents/shopcenter/shopmenu";
import indexCenter from "@/components/center/indexCenter";
import Personal from "@/components/CommonComponents/personalCenter/personal";
import Myprofile from "@/components/CommonComponents/personalCenter/myprofile";
import Ticketlist from "@/components/CommonComponents/personalCenter/ticketlist";
import Orderlist from "@/components/CommonComponents/personalCenter/orderlist";
import Exchange from "@/components/CommonComponents/personalCenter/exchange";
import Collection from "@/components/CommonComponents/personalCenter/collection";
import Mywallet from "@/components/CommonComponents/personalCenter/mywallet";
// import Personalfrom '@/comments/center/per'myprofile
Vue.use(Router);

export default new Router({
  routes: [
    {
      path: "/",
      name: "index",
      component: index
    },
    {
      path: "/TopSubfield",
      name: "TopSubfield",
      component: TopSubfield
    },
    {
      path: "/centerSearch",
      name: "centerSearch",
      component: centerSearch
    },
    {
      path: "/centerTop",
      name: "centerTop",
      component: centerTop
    },
    {
      path: "/login",
      name: "Login",
      component: Login
    },
    {
      path: "/bottomSynopsis",
      name: "bottomSynopsis",
      component: bottomSynopsis
    },
    {
      path: "/msgrelease",
      name: "msgrelease",
      component: msgrelease
    },
    {
      path: "/releaseSuccess",
      name: "releaseSuccess",
      component: releaseSuccess
    },
    {
      path: "/msgreleasestep2",
      name: "msgreleasestep2",
      component: msgreleasestep2
    },
    {
      path: "/broadsideNgn",
      name: "broadsideNgn",
      component: broadsideNgn
    },
    {
      path: "/settled",
      name: "Settled",
      component: Settled
    },
    {
      path: "/detailsContent",
      name: "detailsContent",
      component: detailsContent
    },
    {
      path: "/detailsTop", //全部详情页面
      name: "detailsTop",
      component: detailsTop
    },
    {
      path: "/storeinformation", //店铺主页公共模板
      name: "storeinformation",
      component: storeinformation
    },
    {
      path: "/feedback", //意见反馈页面
      name: "feedback",
      component: feedback
    },
    {
      path: "/Hlpcenter", //帮助中心
      name: "Hlpcenter",
      component: Hlpcenter
    },
    {
      path: "/campus", //校园招聘
      name: "campus",
      component: campus
    },
    {
      path: "/report", //举报
      name: "report",
      component: report
    },
    {
      path: "/protection", //消费保障服务
      name: "protection",
      component: protection
    },
    {
      path: "/submitOrder", //提交订单页
      name: "submitOrder",
      component: submitOrder
    },
    {
      path: "/confirmPayment", //确认支付页
      name: "confirmPayment",
      component: confirmPayment
    },
    {
      path: "/orderFulfillment", //支付完成页
      name: "orderFulfillment",
      component: orderFulfillment
    },
    {
      path: "/articleDetails", //公共商品详情页
      name: "articleDetails",
      component: articleDetails
    },
    {
      path: "/aboutUs", //关于我们
      name: "aboutUs",
      component: aboutUs
    },
    {
      path: "/appdownload", //app下载页面
      name: "appdownload",
      component: appdownload
    },
    {
      path: "/application", //加盟说明
      name: "application",
      component: application
    },
    {
      path: "/directions", //加盟申请
      name: "directions",
      component: directions
    },
    {
      path: "/entering", //商家入驻
      name: "entering",
      component: entering
    },
    {
      path: "/shopmenu", //商家菜单列表
      name: "shopmenu",
      component: shopmenu
    },
    {
      path: "/indexCenter", //首页中部
      name: "indexCenter",
      component: indexCenter
    },
    {
      path: "/Personal", //个人中心
      name: "Personal",
      component: Personal,
      children: [
        {
          path: "/",
          component: Myprofile
        },
        {
          path: "/Personal/Myprofile", //个人中心
          component: Myprofile,
          children: [
            {
              path: "/", //票券列表
              component: Ticketlist
            }
          ]
        },
        {
          path: "/Personal/Ticketlist", //票券列表
          component: Ticketlist
        },
        {
          path: "/Personal/Orderlist", //订单列表
          component: Orderlist
        },
        {
          path: "/Personal/Exchange", //兑换记录
          component: Exchange
        },
        {
          path: "/Personal/Collection", //我的收藏 
          component: Collection
        },
        {
          path: "/Personal/Mywallet", //我的钱包
          component: Mywallet
        }
      ]
    }
  ]
});
